package com.qk.management.service.impl;

import cn.hutool.core.bean.BeanUtil;
import com.qk.domain.business.BusinessCountDO;
import com.qk.domain.clue.ClueCountDO;
import com.qk.management.mapper.BusinessMapper;
import com.qk.management.mapper.ClueMapper;
import com.qk.management.service.ReportOverViewService;
import com.qk.vo.portal.PortalVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class ReportOverViewServiceImpl implements ReportOverViewService {
    @Autowired
    private ClueMapper clueMapper;
    @Autowired
    private BusinessMapper businessMapper;
    @Override
    public PortalVO getReportOverview() {
        ClueCountDO clueCountDO = clueMapper.getClueCount();
        BusinessCountDO businessCountDO = businessMapper.getBusinessCount();
        PortalVO portalVO =BeanUtil.copyProperties(clueCountDO,PortalVO.class);
        BeanUtil.copyProperties(businessCountDO,portalVO);
        return portalVO;
    }
}
